<html>
<head>
    <meta charset="UTF-8">
    <style>
        table
        {
            border-collapse:collapse;
        }
        table,th, td
        {
            padding: 10px;
            border: 1px solid black;
        }
    </style>

</head>
<body>
<center>
    <h3>过期订单</h3>
    <table id="orders">

    </table>
</center>
<script src="js/libs/jquery.js"></script>
<script>
    $.get('/order/list?status=overdue', (data, status) => {
        console.log(data);

        tableContent = `<tr><th>订单编号</th><th>商品</th><th>金额</th><th>下单时间</th><th>状态</th></tr>`;
        for (let order of data) {
            tableContent += `<tr><td>${order.id}</td><td>${order.name}</td>><td>${order.amount}</td><td>${order.orderTime}</td><td>过期</td></tr>`;
        }

        $('#orders').html(tableContent);
    });
</script>
</body>
</html>